Introduce including user provided first-boot config at build time#8692
Introduce including user provided first-boot config at build time#8692igorpecovnik merged 1 commit intomainfrom
Conversation
WalkthroughAdds a pre-autologin check in Changes
Sequence Diagram(s)sequenceDiagram
participant Installer
participant Filesystem
participant DesktopManager
Note over Installer,Filesystem: On image preparation
Installer->>Filesystem: check `${USERPATCHES_PATH}/firstboot.conf`
alt file exists
Filesystem-->>Installer: return file
Installer->>Filesystem: copy to `${SDCARD}/root/.not_logged_in_yet`
Installer->>Installer: log info alert
else file missing
Filesystem-->>Installer: no file
end
Installer->>DesktopManager: enable desktop autologin
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes
Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (1)
action.yml (1)
15-19: Consider splitting unrelated changes into separate PRs.This PR's objective is to "Introduce including user provided first-boot config at build time," but these changes add release artifact cleanup functionality, which appears unrelated to firstboot configuration.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
Disabled knowledge base sources:
- Jira integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (2)
action.yml(2 hunks)lib/functions/rootfs/distro-agnostic.sh(1 hunks)
🧰 Additional context used
🧬 Code graph analysis (1)
lib/functions/rootfs/distro-agnostic.sh (1)
.github/generate_CODEOWNERS.sh (1)
display_alert(6-6)
🔇 Additional comments (2)
action.yml (1)
215-215: LGTM!The usage of
inputs.armbian_release_cleanforremoveArtifactsis correct and properly defaults to"false".lib/functions/rootfs/distro-agnostic.sh (1)
112-116: [scratchpad]The destination path for firstboot.conf is correct.
The review comment incorrectly assumes that
.not_logged_in_yetshould be a separate marker file and thatfirstboot.confshould be copied to a different location.Analysis of the
armbian-firstloginscript shows that/root/.not_logged_in_yetserves a dual purpose:
- Its presence triggers the first-login logic (checked at line 613:
if [[ -f /root/.not_logged_in_yet && -n $(tty) ]]; then)- It contains bash variable definitions that are sourced (line 93:
source "$fp_config") to configure the automated setupThe script validates and sources this file as a bash script (lines 87-93), loading
PRESET_*variables. Thepreset-firstrun.shextension demonstrates this pattern by writing configuration variables directly to.not_logged_in_yet(lines 4-51).Therefore, overwriting the empty marker file created at line 110 with the user's
firstboot.confat line 115 is the intended behavior.Likely an incorrect or invalid review comment.
8df8645 to
5a8c30d
Compare
Description
Inserting
firstboot.conffromuserpatches/folder.Documentation summary for feature / change
Config usage: https://docs.armbian.com/User-Guide_Autoconfig/
How Has This Been Tested?
Checklist:
Summary by CodeRabbit